Skip to content

Update a DWH Integration.

Request

Security
apiKey
Path
dwh_idinteger, (int64)required

The ID of the DWH Integration.

Bodyapplication/jsonrequired
schedule_typestring
Enum:"none""daily""hourly""weekly""monthly""minutes_interval""cron"
schedule_optionstring

The schedule value for the schedule_type. For example, if schedule_type is daily, schedule_option should be a time string like 10:00.

timezonestring

The timezone of the schedule. For example, UTC or Asia/Tokyo.

namestring
basic_configsobject(BasicConfigs)
advanced_configsArray of objects(AdvancedConfigs)

The DWH Integration advanced configs. The configs contain array of of table configs which combine with the basic configs will be used to create Connector Bulkload Session.

output_configobject(OutConfigs)

Config for how data will be imported into TD.

filter_configsArray of objects(FilterConfigs)

Config for how data will be filtered before importing into TD. See the connector filters for more info.

curl -i -X PUT \
  'https://dwh-integration-api.treasuredata.com/v1/dwh/{dwh_id}' \
  -H 'Authorization: YOUR_API_KEY_HERE' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "test",
    "schedule_type": "daily",
    "schedule_option": "11:00",
    "timezone": "Asia/Tokyo",
    "basic_configs": {
      "td_authentication_id": 11,
      "database": "database",
      "table": "table",
      "schema": "test"
    },
    "advanced_configs": [
      {
        "target_table": "test",
        "config": {
          "select": "1",
          "table": "test",
          "source_type": "presto"
        }
      }
    ],
    "output_config": {
      "type": "td",
      "database": "test",
      "table": "test",
      "schema": "test"
    }
  }'

Responses

DWH Integration Updated

Bodyapplication/json
schedule_typestring
Enum:"none""daily""hourly""weekly""monthly""minutes_interval""cron"
schedule_optionstring

The schedule value for the schedule_type. For example, if schedule_type is daily, schedule_option should be a time string like 10:00.

timezonestring

The timezone of the schedule. For example, UTC or Asia/Tokyo.

idinteger, (int64)
namestring

The name of the DWH Integration.

user_idinteger, (int64)

The ID of the user who created the DWH Integration.

account_idinteger, (int64)

The TD Account which the DWH Integration belongs to.

workflow_project_idinteger, (int64)
workflow_project_namestring
dwh_config_idinteger, (int64)
created_atstring, (date-time)
updated_atstring, (date-time)
Response
{ "schedule_type": "none", "schedule_option": "string", "timezone": "string", "id": 0, "name": "string", "user_id": 0, "account_id": 0, "workflow_project_id": 0, "workflow_project_name": "string", "dwh_config_id": 0, "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" }